package com.paic.mhis.hcpms.common.sso.intergration.dao;

import java.util.List;
import java.util.Map;

import com.paic.mhis.hcpms.common.sso.dto.CognosReportDTO;
import com.paic.mhis.hcpms.common.sso.dto.CognosRoleDTO;
import com.paic.pafa.exceptions.BusinessException;

public interface CognosReportDAO {

	public List<CognosReportDTO> queryCognosReportDTO(Map<String, Object> parameter);

	public long queryCognosReportCount(Map<String, Object> parameter);

	/**
	 * 报表信息
	 * 
	 * @param paramMap
	 * @return
	 * @throws BusinessException
	 */
	public List<CognosReportDTO> findCognosReports(Map<String, Object> paramMap) throws BusinessException;

	public void saveCognosReportInfo(CognosReportDTO bean);

	public void updateCognosReportInfo(CognosReportDTO bean);

	public void deleteCognosReportInfo(CognosReportDTO bean);

	/**
	 * 根据报表名称和创建日期加载对应的报表资源信息
	 * 
	 * @param parameter
	 * @return
	 */
	public List<CognosReportDTO> loadSigleCognosReportDTOInfo(Map<String, Object> parameter);

	/**
	 * 根据报表名称和创建日期加载对应的报表资源信息 总记录数
	 * 
	 * @param parameter
	 * @return
	 */
	public long countSigleCognosReportDTOInfo(Map<String, Object> parameter);

	/**
	 * 新增角色与报表关系
	 * 
	 * @param cognosRoles
	 * @throws BusinessException
	 */
	public void saveCognosReportAuthorize(List<CognosRoleDTO> cognosRoles);

	/**
	 * 查询角色与报表信息
	 * 
	 * @param paramMap
	 * @throws BusinessException
	 */
	public List<CognosRoleDTO> cognosReportQueryRole(Map<String, Object> paramMap) throws BusinessException;

	/**
	 * 展示当前已授权报表信息
	 * 
	 * @param paramMap
	 * @return
	 * @throws BusinessException
	 */
	public List<CognosReportDTO> cognosReportAuthorizeQuery(Map<String, Object> paramMap) throws BusinessException;

	/**
	 * 删除角色与报表关系
	 * 
	 * @param ids
	 */
	public void deleteCognosReportRole(Map<String, Object> paramMap);

	public List<CognosReportDTO> queryCognosReportDTOByRoleId(String roleId);

	public List<CognosRoleDTO> queryAllRoleInfo();

}
